/*
 * @Descripttion: 城市页面配置
 * @version: 电子名片2.0
 * @Author: 冯健
 * @Date: 2020-11-24 11:38:49
 * @LastEditors: 冯健
 * @LastEditTime: 2020-12-09 14:57:21
 */
export const listHedar = [
  { label: '城市编号', prop: 'id' },
  { label: '城市名称', prop: 'areaName' },
  { label: '城市主题图片', prop: 'backImg', isTemplate: true },
  { label: '行政区域', prop: 'areaName2' },
  { label: '城市名片人数', prop: 'areaNum' },
  // { label: '热门排序', prop: 'memberState' },
  { label: '类型', prop: 'isHot', isTemplate: true },
  { label: '修改人', prop: 'modifierName' },
  { label: '修改时间', prop: 'gmtModified' },
  { label: '操作', prop: 'operate', isTemplate: true, fixed: 'right' }
]

const types = [
  { value: '1', title: '热门城市' },
  { value: '0', title: '普通城市' }
]
export const searchs = [
  { type: 'input', key: 'keyword', value: '', placeholder: '城市编号、城市名称' },
  { type: 'select', key: 'type', value: '', selectList: types, placeholder: '类型' }
]

export const editList = [
  { type: 'input', key: 'areaName', label: ' 城市名称: ', placeholder: '请输入' },
  { type: 'slot', key: 'areaCode', label: '行政区域: ', name: 'linkage' },
  { type: 'upload', key: 'backImg', label: ' 城市图片: ' },
  { type: 'textarea', key: 'description', label: ' 城市简介: ', placeholder: '请输入' }
]

export const rules = {
  areaName: { required: true, message: '请输入城市名称' },
  backImg: { required: true, message: '请上传城市背景' },
  areaCode: { required: true, message: '请选择行政区域' },
  description: { required: true, message: '请输入城市简介' }
}
